import numpy as np
import pandas as pd

q_table = pd.DataFrame(np.ones((2,4)), index = ['A','B'], columns=['W','A','S','D'])
print(q_table)
add = pd.Series([0.]*4, index=q_table.columns, name='state')
print(add)
q_table = q_table.append(add)
print(q_table)

